package com.lxp.userms.mapper;

import com.lxp.userms.entity.Like;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface LikeMapper {
    int insertLike(Like like);
    Like selectLike(int postId, int userId);
    int deleteLike(int postId, int userId);
    int countLikesByPostId(int postId);
    Like checkLike(int postId, int userId);

    // 确保该方法已定义
    void deleteLikesByPostId(int postId);
}